import './index.scss';
import NavItem from './Item.jsx';

class BottomNav extends React.Component {
  render() {
    return (
      //this.props -> {navData: Array(4)}
      //this.props.navData -> ['第一', '第二', '第三', '第四']
      <div className="bottom-nav">
        {this.props.navData.map((item, index) => {
          return <NavItem item={item} index={index} key={index}></NavItem>;
        })}
      </div>
    );
  }
}

export default BottomNav;
